package com.lzc.springPart.aop;


import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

@Aspect
@Component
public class MyAspect {

    @Pointcut("@annotation(com.lzc.springPart.aop.PrintBefore)")
    public void pc(){}

    @Before("pc()")
    public void before(){
        System.out.println("before");
    }

}
